1. Field of the Invention
The present invention relates to a character recognition apparatus. The present invention relates, in particular, to a character recognition apparatus which inputs image information including characters such as those in a document, as image data, by an image scanner or a facsimile, extracts a characteristic quantity of a character from the image data, compares the extracted characteristic quantity with standard characteristic quantities which are memorized in a dictionary, and recognizes the character.
2. Description of the Related Art
FIG. 1 shows a flow of main processes in the conventional character recognition apparatus.
In the step 401, the image of a document, characters which are to be recognized, is input as image data by an image scanner or the like, and is stored in a memory.
In the step 402, a region wherein successive character strings, i.e., a region wherein sentences are printed, is extracted and distinguished from other regions such as a picture, or a drawing, or the like.
In the step 403, a region of each character string is extracted from the above region wherein sentences are printed.
In the step 404, a region of each character (a character image) is extracted from the above character string.
In the step 406, a characteristic quantity of the character is extracted from the above modified character image by a predetermined procedure.
In the step 407, the above extracted characteristic quantity is compared with each of the plurality of characters which are memorized in the dictionary, one by one, and then a character which is most similar to the extracted characteristic quantity is recognized as a character which the above character image represents (step 488).
Next, in the step 489, it is determined whether or not the result of above character recognition is correct. If it is determined that the above recognition result is incorrect, a correction is carried out in the step 490, and the corrected character recognition result is stored in the memory in the step 491.
An example of the above procedure for extracting a characteristic quantity is shown in FIGS. 2 to 6.
Namely, when a character image as shown in FIG. 2 is extracted from an image which is input by an image scanner or the like, next, a contour of the character image is extracted as shown in FIG. 3, and the contour image is divided into a n.times.m (for example, 8.times.8) meshes. Then, the above contour line is decomposed into directional line segments in each mesh as shown in FIG. 4, and the number of directional line segments in each direction is detected in each mesh. FIG. 4 is a magnified view of the mesh (8, 1) into a further fine 8.times.8 meshes. Then, aspects of connection of contour points on the contour of the character image in the respective meshes are accumulated for four directions as shown in FIG. 5 to extract a characteristic quantity (A.sub.i,j, B.sub.i,j, D.sub.i,j).
Here, the above directions can be classified, for example, as shown in FIG. 5, into four directions: a right-left direction, a right-down direction, an up-down direction, and a left down direction, where the right-left direction is denoted by "0", the right-down direction is denoted by "1", the up-down direction is denoted by "2", and the left-down direction is denoted by "3". In the determination result of FIG. 4, A.sub.i,j, B.sub.i,j, C.sub.i,j, D.sub.i,j, respectively denote a number of directional line segments in the direction "0", a number of directional line segments in the direction "1", a number of directional line segments in the direction "2", and a number of directional line segments in the direction "3", in the mesh i,j. Thus, the characteristic quantity (A.sub.8,1, B.sub.8,1, C.sub.8,1, D.sub.8,1) of FIG. 4 is (11, 0, 2, 4). Namely, a four-dimensional vector quantity, which four dimensions correspond to the above four directions, is extracted in each mesh, and thus, four-dimensional vector quantities (A.sub.i,j, B.sub.i,j, C.sub.i,j, D.sub.i,j) are obtained for all the meshes as shown in FIG. 6. When the meshes are 8.times.8, a 256-dimensional vector quantity is obtained as a characteristic quantity of a character by a direct product of the above 8.times.8 four-dimensional vector quantities (A.sub.i,j, B.sub.i,j, C.sub.i,j, D.sub.i,j).
Generally, in character recognition apparatuses, the following are required: a recognition rate is high (the number of erroneous recognitions is small); a time necessary to obtain a recognition result is short; a processing speed is high; a hardware size is small; and an operation for recognizing a character is simple and can be effectively carried out.
However, in the above-mentioned conventional character recognition apparatus, when a font corresponding to the characteristic quantities memorized in the dictionary, and a font of the image data which is input are different, or when sizes of characters memorized in the dictionary, and a size of a character of the image data which is input are different, the content of the dictionary is replaced with the characteristic quantity of the image data, or with a weighted average of the content of the dictionary and the characteristic quantity of the image data, every time an incorrect recognition occurs. In the above conventional character recognition apparatus, if replaced with the characteristic quantity of the image data, variation of the characteristic quantities memorized in the dictionary is large, or if replaced with the weighted average of the content of the dictionary and the characteristic quantity of the image data, a response (learning speed) of the dictionary to variation of input image data is slow. In either case, the above situations tend to cause an erroneous recognition, and the above replacing procedures make operations bothersome.
Another problem in the above conventional character recognition apparatus is that, when a small deformation occurs in an input image data due to a slippage of a position of the image data or a variation of concentration or a blur, the deformation is recognized as a characteristic feature of a character, and causes a degradation of a recognition rate.
Still another problem in the above conventional character recognition apparatus is that, an incorrect recognition must be detected by operator's eyes by finding an unnatural sentence obtained by an incorrect recognition, or by comparing recognition result with input image data, i.e., operations are bothersome and inefficient.
A further problem in the above conventional character recognition apparatus is that, in the above comparison with the input image data, it is bothersome and inefficient to locate a corresponding portion of the input image data when a recognized character seems to be incorrect.
A still further problem in the above conventional character recognition apparatus of FIG. 1, is that, in the step 402, a region wherein successive character strings, i.e., a region wherein sentences are printed, is extracted from other regions of a continuous image such as a picture, or a drawing, or the like, a labeling of each dot regarding which region each dot belongs to, is carried out dot by dot, or a similar labeling is carried out for each small region after the input image data is divided into a number of small regions. When the former labeling is carried out, an amount of data which is processed is large, a large size of hardware and a long processing time are necessary, due to the dot-by-dot labeling. In the latter labeling, when the sizes of the small regions are large, a processing speed is large, but resolution is low, or when the sizes of the small regions are made small to improve the resolution, the processing speed becomes low, and the large size of hardware such as a large memory, is necessary.